package com.spic.business.blast.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.spic.business.blast.domain.BlastDeployment;
import com.spic.business.blast.domain.BlastDeploymentDetonatorSubtable;
import com.spic.business.blast.domain.BlastDeploymentExplosiveSubtable;
import com.spic.business.blast.domain.BlastDeploymentHoleSubtable;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
 * 爆破布防Mapper接口
 *
 * @author spic
 * @date 2022-03-03
 */
@Mapper
public interface BlastDeploymentMapper extends BaseMapper<BlastDeployment>
{
    /**
     * 查询爆破布防
     *
     * @param id 爆破布防主键
     * @return 爆破布防
     */
    public BlastDeployment selectBlastDeploymentById(String id);

    public List<BlastDeployment> selectBlastDeploymentByIds(String[] id);

    /**
     * 查询爆破布防列表
     *
     * @param blastDeployment 爆破布防
     * @return 爆破布防集合
     */
    public List<BlastDeployment> selectBlastDeploymentList(BlastDeployment blastDeployment);

    public List<BlastDeployment> selectBlastDeploymentListAllByCode(BlastDeployment blastDeployment);

    public List<BlastDeployment> selectBlastDeploymentListByCode(BlastDeployment blastDeployment);

    /**
     * 新增爆破布防
     *
     * @param blastDeployment 爆破布防
     * @return 结果
     */
    public int insertBlastDeployment(BlastDeployment blastDeployment);


    public BlastDeployment selectBlastDeploymentByCode(String code);
    /**
     * 修改爆破布防
     *
     * @param blastDeployment 爆破布防
     * @return 结果
     */
    public int updateBlastDeployment(BlastDeployment blastDeployment);

    /**
     * 删除爆破布防
     *
     * @param id 爆破布防主键
     * @return 结果
     */
    public int deleteBlastDeploymentById(String id);

    /**
     * 批量删除爆破布防
     *
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteBlastDeploymentByIds(String[] ids);

    /**
     * 批量删除孔数信息子
     *
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteBlastDeploymentHoleSubtableByIds(String[] ids);

    /**
     * 批量新增孔数信息子
     *
     * @param blastDeploymentHoleSubtableList 孔数信息子列表
     * @return 结果
     */
    public int batchBlastDeploymentHoleSubtable(List<BlastDeploymentHoleSubtable> blastDeploymentHoleSubtableList);


    /**
     * 通过爆破布防主键删除孔数信息子信息
     *
     * @param id 爆破布防ID
     * @return 结果
     */
    public int deleteBlastDeploymentHoleSubtableByBlastDeploymentId(String id);

    /**
     * 批量删除炸药子
     *
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteBlastDeploymentExplosiveSubtableByIds(String[] ids);

    /**
     * 批量新增炸药子
     *
     * @param blastDeploymentExplosiveSubtableList 炸药子列表
     * @return 结果
     */
    public int batchBlastDeploymentExplosiveSubtable(List<BlastDeploymentExplosiveSubtable> blastDeploymentExplosiveSubtableList);


    /**
     * 通过爆破布防主键删除炸药子信息
     *
     * @param id 爆破布防ID
     * @return 结果
     */
    public int deleteBlastDeploymentExplosiveSubtableByBlastDeploymentId(String id);

    /**
     * 批量删除雷管个数子表数据
     *
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteBlastDeploymentDetonatorSubtableByIds(String[] ids);

    /**
     * 批量新增雷管个数子表数据
     *
     * @param blastDeploymentDetonatorSubtableList 雷管个数子表数据列表
     * @return 结果
     */
    public int batchBlastDeploymentDetonatorSubtable(List<BlastDeploymentDetonatorSubtable> blastDeploymentDetonatorSubtableList);


    /**
     * 通过爆破布防主键删除炸雷管个数子表数据
     *
     * @param id 爆破布防ID
     * @return 结果
     */
    public int deleteBlastDeploymentDetonatorSubtableByBlastDeploymentId(String id);
}
